package com.csw.android.ffmpegtest.gl.base

import android.opengl.GLSurfaceView
import javax.microedition.khronos.egl.EGLConfig
import javax.microedition.khronos.opengles.GL10

open class BaseNativeRenderer : GLSurfaceView.Renderer {

    protected val glV3Renderer = GLV3Renderer()

    override fun onSurfaceCreated(gl: GL10?, config: EGLConfig?) {
        glV3Renderer.nativeOnSurfaceCreated()
    }

    override fun onSurfaceChanged(gl: GL10?, width: Int, height: Int) {
        glV3Renderer.nativeOnSurfaceChanged(width, height)
    }

    override fun onDrawFrame(gl: GL10?) {
        glV3Renderer.nativeOnDrawFrame()
    }
}